package org.aileen.mybatis.mapper;

import org.aileen.mybatis.model.UserInfo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface UserInfoXMLMapper {

    //查询
    /**
     * 方式1:取别名,直接在xml修改SQL语句
     */
    List<UserInfo> queryUserInfos();


    List<UserInfo> queryUserInfos2();

    //------------------

    //增加
    Integer insetUserInfos(UserInfo userInfo);

    //改:
    Integer updateUserInfo(UserInfo userInfo);

    //删:
    Integer deleteUserInfo(Integer id);//根据ID进行删除

    //--------------动态SQL----------------------
    Integer insertByCondition(UserInfo userInfo);

    List<UserInfo> selectByCondition(UserInfo userInfo);

    Integer updateByCondition(UserInfo userInfo);

    Integer updateByCondition2(UserInfo userInfo);

    Integer batchDelete(List<Integer> ids);





}
